#ifndef OCSAMPLE_COMMON_H
#define OCSAMPLE_COMMON_H

#include <iostream>
//--------------------OpenCV头文件---------------
#include <opencv2/opencv.hpp>
#include <opencv2/core/version.hpp>
using namespace cv;

#if CV_VERSION_EPOCH == 2
#define OPENCV2
#include <opencv2/gpu/gpu.hpp>
using namespace cv::gpu;

#elif CV_VERSION_MAJOR == 3
#define  OPENCV3
#include <opencv2/core/cuda.hpp>
using namespace cv::cuda;

#else
#error Not support this OpenCV version
#endif
//--------------------OpenCV头文件---------------

using namespace std;
#endif //OCSAMPLE_COMMON_H
